<div class="incident-list" ng-controller="knowledgeManagerCtrl"> <!--id="scrollArea" style="height:800px;overflow: auto;"-->
<!--CKeditor start-->
<!-- <script src="assets/ckeditor/ckeditor.js"></script>  -->
<!--CKeditor end-->
<!-- <script src="assets/bootstrap-star-rating-master/js/star-rating.min.js"></script> 
<link rel="stylesheet" type="text/css" href="assets/bootstrap-star-rating-master/css/star-rating.min.css"/> -->
<!-- 
<script src="assets/javascripts/jquery.form.js"></script>  -->
<style>
li{
 list-style-type:none;
}
.dashborder{
  border:1px dashed #CCCCCC;
}
.select_side{
  float:left; 
  width:350px;
 /* border-color: #DDD;*/
  background-color: #F5F5F5;
} 
select{width:300px; height:200px} 
.select_opt{ 
  float:left; 
  width:20px; 
  height:100%;
  margin-top:46px;
} 
.select_opt p{ 
  width:26px; 
  height:26px; 
  margin-top:6px; 
  background:url(images/arr.gif) no-repeat; 
  cursor:pointer; 
  text-indent:-999em
} 
.select_opt p#toright{ 
  background-position:2px 0;
} 
.select_opt p#toleft{
  background-position:2px -22px;
} 
.sub_btn{
  margin-top:10px;
  vertical-align: middle;
  text-align: center;
  margin-left: auto;
}
.no_boder{
   border-left: 0;
   border-right: 0;
   border-top: 0;
   border-bottom:0;
   background-color: #f5f5f5;
}

</style>
<!-- start: PAGE TITLE -->
<section id="page-title">
  <div class="row">
    <div class="col-sm-8">
      <h1 class="mainTitle" translate="sidebar.nav.knowledgebase.MAIN">{{ mainTitle }}</h1>
      <span class="mainDescription" translate="sidebar.nav.knowledgebase.MAINDesc">A type of data structure in which each element is attached to one or more elements directly beneath it. The connections between elements are called branches. <small class="block">Webopedia - Online Tech Dictionary for IT Professionals</small></span>
    </div>
    <!-- <div ncy-breadcrumb></div> -->
  </div>
</section>
<div class="container-fluid container-fullw bg-white">
  <div class="row" ng-controller="knowledgeManagerCtrl">
    <div class="col-md-2 col-sm-2">
      <a class="btn btn-wide btn-primary" ng-click="createKnowledge('lg')"><i class="fa fa-edit"></i>新建知识</a><hr />
      <h5 class="over-title margin-bottom-15"><i class="fa fa-building-o"/><span class="text-bold" translate="sidebar.nav.knowledgebase.Classic">CI Manager</span></h5>
      <div>
        <div class="row">
            <div class="panel panel-white">
              <div class="panel-body">
                <div class="box-tree">
                  <span ng-if="doing_async">...加载中...</span>
                  <abn-tree tree-data="my_data" tree-control="my_tree" on-select="my_tree_handler(branch)" expand-level="2" icon-leaf="ti-file" icon-expand="ti-plus" icon-collapse="ti-minus"></abn-tree>
                </div>
              </div>
            </div>
            <div class="alert alert-warning">
              {{ output }}
            </div>
        </div>
      </div>
    </div>
    <div class="col-md-10 col-sm-10">
        <div class="list-container-header">
          <div class="col-md-4"><label style="font-size:25px;"><i class="fa fa-book">知识库列表</i></label></div>
          <div class="col-md-offset-5 col-md-3 pull-right">
            <div class="form-group">
                <div class="input-group">
                  <input type="text" class="form-control" ng-model="searchSolutionInput" placeholder="请输入关键字搜索">
                  <span class="input-group-btn">
                    <button type="button" class="btn btn-warning" ng-click="searchSolution()">
                      <i class="fa fa-search"></i>  
                    </button></span>
                </div>
            </div>
          </div>
        </div>
        <div class="list-controls clearfix">
          <div class="btn-group">
            <a ladda="ldloading.expand_right" class="btn btn-wide btn-info" data-style="expand-right" ng-click="reload()" tooltip="刷新"><i class="fa fa-repeat"></i></a>
            <div class="btn-group" dropdown tooltip="类型查询">
              <button type="button" class="btn btn-wide btn-blue dropdown-toggle" dropdown-toggle ng-disabled="disabled">
                <i class="fa fa-check-square-o"/> <span class="caret"></span>
              </button>
              <ul class="dropdown-menu" role="menu">
                <li ng-repeat="choice in statuses">
                  <a ng-click="filterSolutionStatus(choice.status)">{{choice.label}}</a>
                </li>
              </ul>
            </div>
            <button type="button" class="btn btn-warning" tooltip="审核授权" ng-click="reviewKnowledgeType();" ng-show="showReviewKnowledgeType"><i class="btn-label icon fa fa-send"></i>    
            </button>
            <!-- <div class="btn-group" dropdown tooltip="编辑知识库类型" ng-if="showAddSolutionType">
              <button type="button" class="btn btn-wide btn-blue dropdown-toggle" dropdown-toggle ng-disabled="disabled">
                <i class="fa fa-pencil-square-o"/> <span class="caret"></span>
              </button>
              <ul class="dropdown-menu" role="menu">
                <li>
                  <a ng-click="editKnowledgeType(true)">新增</a>
                </li>
                <li>
                  <a ng-click="editKnowledgeType(false)">修改</a>
                </li>
                <li>
                  <a ng-click="removeKnowledgeType()">删除</a>
                </li>
              </ul>
            </div> -->
            <!-- <button type="button" class="btn btn-success" tooltip="编辑知识库类型" tooltip-placement="right"  ng-if="showAddSolutionType">
                <i class="fa fa-pancil-o"></i>
            </button> -->
          </div>
        </div>
        <div class="list-controls clearfix">
          <!--知识库列表 start -->
          <div ui-i18n="{{lang}}" class="list" >
              <div id="gridknowledge" ui-grid="gridOptions" ui-grid-pagination external-scopes="$scope" ui-grid-cellNav ui-grid-resize-columns ui-grid-selection class="grid"></div>
          </div>
        </div>

    </div>
  </div>
</div>



<!--审核知识库类型 start-->
    <div id="reviewKnowledgeType" class="modal fade modal-blur" tabindex="-1" role="dialog" style="display:none;">
          <div class="modal-dialog" >
                <div class="modal-content panel-info" style="width:800px;">
                   <div class="modal-header panel-heading panel-dark">
                      <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                      <h4 class="modal-title"><i class="fa fa-gavel"></i>知识库类型授权</h4>
                  </div>
                  <div class="modal-body">
                      <!--授权 start -->
                              <div class="row form-group">
                                    <label for="actionType1" class="col-md-2 control-label">权限类型:</label>
                                    <div class="col-md-8">
                                      <select  id="actionType1" class="form-control"  
                                         ng-model="actionType"  data-placeholder="权限类型">
                                                <option ng-repeat="r in actionTypes" value="{{r.id}}" ng-selected="{{r.id == 1}}" >{{r.name}}</option>
                                        </select>  
                                    </div>
                              </div>
                               <div class="row form-group" style="padding-left:25px;">
                                    <div class="col-md-5" style="width:350px;margin-right:20px;">
                                       <div id="jsTreeType">
                                          <div class="row" cg-busy="vm.promise">
                                              <toaster-container></toaster-container>
                                              <div class="panel panel-info">
                                                 <div class="panel-heading">
                                                     <i class="glyphicon glyphicon-tree-conifer"></i>知识库分类
                                                 </div> 
                                                 <div class="panel-body">
                                                      <div js-tree="vm.treeConfig"  ng-model="vm.treeData.typeData" should-apply="vm.applyModelChanges()" tree-events="select_node:vm.nodeSelected;ready:vm.readyCB;create_node:vm.createCB;">
                                                      </div>
                                                 </div>
                                             </div>
                                          </div>
                                      </div>
                                   </div> 
                                   <div class="col-md-5">
                                      <div id="jsTreeGroup"> 
                                          <div class="row" cg-busy="vm.promise">
                                              <toaster-container></toaster-container>
                                          <div> 
                                          <div class="panel panel-info">
                                             <div class="panel-heading">
                                                 <i class="glyphicon glyphicon-tree-conifer"></i>工作组
                                             </div> 
                                             <div class="panel-body">
                                                  <div js-tree="vm.treeConfig"  ng-model="vm.treeData.groupData" should-apply="vm.applyModelChanges()" tree-events="select_node:vm.nodeSelected;ready:vm.readyCB;create_node:vm.createCB">
                                                  </div>
                                             </div>
                                         </div>
                                        </div>
                                       </div>
                                   </div> 
                                 </div>
                              </div> <!--row -->
                              <div class="row form-group" style="padding-left:25px;"> 
                                <div  class="col-md-15"> 
                                    <div class="select_side" > 
                                        <div class="panel panel-info">
                                             <div class="panel-heading">
                                                 <i class="glyphicon glyphicon-tree-conifer"></i>待选区
                                             </div> 
                                             <div class="panel-body"> 
                                               <select id="selectL" name="selectL"  multiple="multiple"  
                                                        ng-model="selectModelL"  ng-options=" (o.order+'--'+o.name) for o in peopleL | index"  
                                                        ng-change="selChange(selectModelL)">
                                                     <option value=""></option>     
                                               </select>
                                                <div class="sub_btn"><input type="button" class="btn btn-info" id="sub1" value="保存" ng-click="save()"/></div>  
                                              </div>
                                          </div>
                                   </div> 

                                  <div class="select_opt"> 
                                       <p id="toright" title="添加" ng-click="findSelectR()">></p> 
                                       <p id="toleft" title="移除" ng-click="findSelectL()"><</p> 
                                  </div> 

                                 <div class="select_side"> 
                                       <div class="panel panel-info">
                                             <div class="panel-heading">
                                                 <i class="glyphicon glyphicon-tree-conifer"></i>已选区
                                             </div> 
                                             <div class="panel-body"> 
                                                 <select id="selectR" name="selectR" multiple="multiple" 
                                                         ng-model="selectModelR" ng-options=" (o.order+'--'+o.name)  for o in peopleR | index"  
                                                          ng-change="selChange(selectModelR)"> 
                                                 </select> 
                                                 <div class="sub_btn"><input type="button" class="btn btn-info"  id="sub2" value="赋予全体用户权限" ng-click="saveAll()"/></div>    
                                            </div> 
                                    </div>
                                 </div>
                              </div>
                            </div><!--row -->
                        </div> 
                     <!--授权 end -->
                 </div>
              </div>
         </div>
 <!--审核知识库类型 end-->    


<!--审核知识库 start-->
    <div id="reviewKnowledge" class="modal fade modal-blur" tabindex="-1" role="dialog" style="display:none;" >
          <div class="modal-dialog">
                <div class="modal-content panel-info" style="width:800px;">
                   <div class="modal-header panel-heading">
                      <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                      <h4 class="modal-title"><i class="fa  fa-gears"></i>审核知识库</h4>
                  </div>
                  <div class="modal-body" >
                     <ul id="uidemo-tabs-default-demo" class="nav nav-tabs" style="margin-top: 20px">
                          <li ng-repeat="tab in reviewKnowledge.tabs" ng-class="tab.active">
                          <a  data-toggle="tab"  ng-click="reviewKnowledge.tabselect(tab.id);">{{tab.title}}</a>
                           </li>
                      </ul>

                      <div class="tab-content tab-content-bordered">  
                      <!--编辑知识库 start-->
                        <div class="tab-pane fade" ng-class="reviewKnowledge.tabs[0].divactive">
                              <div class="row form-group"> 
                                     <label class="col-md-2 control-label">附件
                                        <a  href="http://{{path}}/services/solution/download/{{entity.id}}">
                                          <img src="{{entity.filePic}}" >
                                        </a>
                                      </label>
                                     <div class="col-md-4"> 
                                      <input type="hidden" id="fileNames" ng-model="entity.fileName"  value="{{entity.fileName}}">
                                        {{entity.fileName}}
                                    </div> 
                                     <!--label class="col-md-2 control-label" for="publishRange">发布范围</label> 
                                     <div class="col-md-4">
                                      <select  id="publishRange" class="form-control"  
                                         ng-model="entity.publishRange"  data-placeholder="选择发布范围">
                                                <option ng-repeat="r in publishRanges" value="{{r.id}}">{{r.name}}</option>
                                        </select>   
                                    </div--> 
                            </div>       
                            <div class="row form-group" id="reviewBtns">
                                 <label class="col-md-2 control-label" ></label>
                                 <div class="col-md-4"></div>  
                                    

                                 <!--  <label class="col-md-2 control-label"> 审核： </label> -->
                                  <!--div class="col-xs-6 col-md-6">
                                      <div ng-show="!showOutTime" style="float:right;"> 
                                         <button type="button" class="btn btn-info" ng-click="verifySolution('publish');" ng-show="entity.outtime">发布</button>
                                  
                                        <button type="button" class="btn btn-default" ng-click="verifySolution('outtime');" ng-show="entity.outtime">撤销</button>
                                      </div>
                                      
                                      <!--div ng-show="showOutTime" style="float:right;">
                                        <button type="button" class="btn btn-info disabled" >发布</button>
                                        <button type="button" class="btn btn-default disabled">撤销</button>
                                      </div>

                                      <div ng-show="couldReview" style="float:right;">
                                          <button type="button" class="btn btn-success" ng-click="verifySolution('success');">通过</button>
                                        
                                          <button type="button" class="btn btn-danger" ng-click="verifySolution('failed');">驳回</button>
                                          <button type="button" class="btn btn-warning" ng-click="verifySolution('reject');">拒绝</button>
                                      </div> 
                                       <!--div ng-show="!couldReview" style="float:right;">
                                            <button type="button" class="btn btn-success disabled">通过</button>
                                            <button type="button" class="btn btn-danger disabled">驳回</button>
                                            <button type="button" class="btn btn-warning disabled">拒绝</button>
                                       </div>
                                  </div-->   
                             </div>
                            <div class="row form-group">
                                    <label class="col-md-2 control-label" for="title">
                                            标题:
                                    </label>
                                    <div class="col-md-4">
                                        <input id="title" name="title" class="form-control"  ng-model="entity.title" placeholder="标题" />
                                    </div>
                                     <label class="col-md-2 control-label" for="keys">关键字:</label>
                                     <div class="col-md-4">
                                           <input  class="form-control" id="keys" ng-model="entity.keys" name="keys"  placeholder="关键字" />
                                     </div> 
                            </div>
                             <div class="row form-group">
                                 <label class="col-md-2 control-label" for="type">分类:</label>
                                 <div class="col-md-4">
                                      <input  id="type1" name="type1" ng-model="entity.typeName" class="form-control"  placeholder="分类"
                                          ng-click="doOnLoad1('type1');" data-toggle="modal" data-target="#typeboxbox"
                                          > 
                                         <input type="hidden" id="type1id" name="type1Id" ng-model="entity.type">  
                                 </div> 
                                 <label class="col-md-2 control-label" for="range">使用范围:</label>
                                 <div class="col-md-4">
                                      <select  id="range" class="form-control"  
                                         ng-model="entity.range"  data-placeholder="选择使用范围">
                                                <option ng-repeat="r in ranges" value="{{r.id}}">{{r.name}}</option>
                                        </select>   
                                </div> 
                            </div>
                                 
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="number">知识库编号:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                          <input  id="number" name="number"  ng-model="entity.number" class="form-control"  placeholder="知识库编号"> 
                                    </div>             
                            </div>
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="content">知识库内容:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                      <textarea ckeditor ng-model="entity.content" class="form-control"></textarea>
                                    </div>             
                            </div>
                            <input type="hidden" ng-model="entity.id">
                            <div class="panel-footer text-center">
                                   <a ng-click="updateSolution();"  data-dismiss="modal" class="btn btn-primary">提交</a>
                                  <a  data-dismiss="modal" class="btn btn-primary">取消</a>
                               </div>
                         </div><!--tab-pane fade -->
                        <!--审核页面 start-->
                         <div class="tab-pane fade" ng-class="reviewKnowledge.tabs[1].divactive">
                              <div class="row form-group" ng-show="publishbox"> 
                                     <label class="col-md-2 control-label" for="publishRange">发布范围</label> 
                                     <div class="col-md-4">
                                      <select  id="publishRange" class="form-control"  
                                         ng-model="entity.publishRange"  data-placeholder="选择发布范围">
                                                <option ng-repeat="r in publishRanges" value="{{r.id}}">{{r.name}}</option>
                                        </select>   
                                    </div> 
                            </div>       
                            <div class="row form-group" id="reviewBtns">
                                 <label class="col-md-2 control-label" >审核</label>
                                  <div class="col-xs-6 col-md-6">
                                      <div ng-show="!showOutTime" style="float:right;"> 
                                         <button type="button" class="btn btn-info" ng-click="verifySolution('publish');" ng-show="entity.outtime">发布</button>
                                  
                                        <button type="button" class="btn btn-default" ng-click="verifySolution('outtime');" ng-show="entity.outtime">撤销</button>
                                      </div>
                                      
                                      <!--div ng-show="showOutTime" style="float:right;">
                                        <button type="button" class="btn btn-info disabled" >发布</button>
                                        <button type="button" class="btn btn-default disabled">撤销</button>
                                      </div-->

                                      <div  style="float:right;" ng-show="couldReview">  
                                          <button type="button" class="btn btn-success" ng-click="verifySolution('success');">通过</button>
                                        
                                          <button type="button" class="btn btn-danger" ng-click="verifySolution('failed');">驳回</button>
                                          <button type="button" class="btn btn-warning" ng-click="verifySolution('reject');">拒绝</button>
                                      </div> 
                                       <!--div ng-show="!couldReview" style="float:right;">
                                            <button type="button" class="btn btn-success disabled">通过</button>
                                            <button type="button" class="btn btn-danger disabled">驳回</button>
                                            <button type="button" class="btn btn-warning disabled">拒绝</button>
                                       </div-->
                                  </div>   
                             </div>
                             <div class="row form-group" ng-show="showReason"> 
                                     <label class="col-md-2 control-label" for="reasons">{{reasonName}}意见</label> 
                                     <div class="col-md-8">
                                      <textarea ckeditor id="reasonval" ng-model="reason" class="form-control"></textarea>
                                    </div> 
                            </div>   
                            <input type="hidden" ng-model="entity.id">
                             <div class="panel-footer text-center">
                                   <a ng-click="verifySolutions('{{verifyType}}');"  data-dismiss="modal" class="btn btn-primary">提交</a>
                                  <a  data-dismiss="modal" class="btn btn-primary">取消</a>
                             </div> 
                         </div>
                         <!--审核页面 end -->

                      <!--授权 start -->
                      <div class="tab-pane fade {{reviewKnowledge.tabs[2].divactive}}"> <!-- ng-controller="soltctrl as vm" --> 
                               <div class="row form-group">
                                  <div class="col-md-8">
                                    <label for="actionTypes" class="col-xs-3 control-label">权限类型:</label>
                                    <div class="col-xs-8">
                                      <select  id="actions" class="form-control"  
                                         ng-model="actionType"  data-placeholder="权限类型">
                                                <option ng-repeat="r in solutionActionTypes" value="{{r.id}}" ng-selected="{{r.id == 1}}">{{r.name}}</option>
                                        </select>  
                                    </div>
                                  </div>
                                 </div> 
                                <div class="row form-group"  style="margin-left:15px;">
                                 <div class="col-md-8">
                                      <div id="jsTreeGroups" > 
                                          <div class="row" cg-busy="vm.promise">
                                              <toaster-container></toaster-container>
                                          <div> 
                                          <div class="panel panel-info">
                                             <div class="panel-heading">
                                                 <i class="glyphicon glyphicon-tree-conifer"></i>工作组
                                             </div> 
                                             <div class="panel-body">
                                                  <div js-tree="vm.treeConfig"  ng-model="vm.treeData.groupData" should-apply="vm.applyModelChanges()" tree-events="select_node:vm.nodeGroupSelected;ready:vm.readyCB;create_node:vm.createCB">
                                                  </div>
                                             </div>
                                         </div>
                                        </div>
                                       </div>
                                   </div> 
                                 </div>
                             </div>  <!--row -->
                            <div class="row form-group" >
                                <div  class="col-md-15" style="padding-left:25px;">
                                    <div class="select_side" > 
                                        <div class="panel panel-info">
                                             <div class="panel-heading">
                                                 <i class="glyphicon glyphicon-tree-conifer"></i>待选区
                                             </div> 
                                             <div class="panel-body"> 
                                               <select id="selectL" name="selectL"  multiple="multiple"  
                                                        ng-model="selectModelL"  ng-options=" (o.order+'--'+o.name) for o in peopleL | index"  
                                                        ng-change="selChange(selectModelL)">
                                                     <option value=""></option>     
                                               </select>
                                                <div class="sub_btn"><input type="button" class="btn btn-info" id="sub1" value="保存" ng-click="saveSolution()"/></div>  
                                              </div>
                                          </div>
                                   </div> 

                                  <div class="select_opt"> 
                                       <p id="toright" title="添加" ng-click="findSelectR()">></p> 
                                       <p id="toleft" title="移除" ng-click="findSelectL()"><</p> 
                                  </div> 

                                 <div class="select_side"> 
                                       <div class="panel panel-info">
                                             <div class="panel-heading">
                                                 <i class="glyphicon glyphicon-tree-conifer"></i>已选区
                                             </div> 
                                             <div class="panel-body"> 
                                                 <select id="selectR" name="selectR" multiple="multiple" 
                                                         ng-model="selectModelR" ng-options=" (o.order+'--'+o.name)  for o in peopleR | index"  
                                                          ng-change="selChange(selectModelR)"> 
                                                 </select> 
                                                 <div class="sub_btn"><input type="button" class="btn btn-info"  id="sub2" value="赋予全体用户权限" ng-click="saveAllSolution()"/></div>    
                                            </div> 
                                    </div>
                               </div>
                             </div>
                            </div><!--row -->
                          <!-- </div> -->
                       </div><!--tab-pane fade  -->
                   <!--授权 end -->

                 </div><!--tab-content-->
              </div><!--content-body-->
            </div>
        </div> 
    </div> 
    <!--审核知识库 end-->      

    <!--编辑知识库 start-->     
    <div id="updateSolution" class="modal fade modal-blur" tabindex="-1" role="dialog" style="display: none;">
          <div class="modal-dialog">
                <div class="modal-content panel-warning" style="width:800px;">
                      <div class="modal-header panel-heading">
                         <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                         <h4 class="modal-title"><i class="fa  fa-edit"></i>编辑知识库</h4>
                     </div>
                        <div class="modal-body ">
                              <form   action="#" method="post" enctype="multipart/form-data" id="updateform"  target="idiframes"> 
                              <input type="hidden" id="approveTime" name="approveTime">
                              <input type="hidden" id="approveUserId" name="approveUserId">
                              <input type="hidden" id="createTime" name="createTime">
                              <input type="hidden" id="createrUserId" name="createrUserId">
                              <input type="hidden" id="hits" name="hits">
                              <input type="hidden" id="renewTime" name="renewTime">
                              <input type="hidden" id="renewUserId" name="renewUserId">
                              <input type="hidden" id="status" name="status">
                              <input type="hidden" id="relateId" name="relateId">
                              <input type="hidden" id="id" name="id">
                              <input type="hidden" id="vision" name="vision">

                                <div class="row form-group">
                                   <label class="checkbox-inline">
                                        <input id="attachcheck2" type="checkbox" class="px"  style="margin-left:1px">
                                        <span class="lbl"  style="margin-left:12px">附件</span>
                                         <a  href="http://{{path}}/services/solution/download/{{entity.id}}">
                                          <img src="{{entity.filePic}}" >
                                        </a>
                                        {{entity.fileName}}
                                   </label>
                                    <div id="attachdiv2" class="dropzone-box dz-clickable hidden" style="margin-top: 10px">
                                        <div class="dz-default dz-message"> 
                                            <i class="fa fa-cloud-upload"></i> 
                                            <input  type="file" name="fileContent" id="fileContent"  value="" />
                                            <input  type="hidden" name="fileName" id="fileName"  />
                                            <label>提示：上传txt文档以及Office文档不能超过10M,其他文档不能超过200M 
                                            </label>
                                        </div>   
                                     </div> 
                                 </div>
                                
                                  <div class="row form-group">
                                       <label class="col-md-2 control-label" for="vision"></label>
                                       <div class="col-md-4"></div>
                                       <label class="col-md-2 control-label" for="vision">
                                            版本:
                                       </label>
                                       <div class="col-md-4">
                                             <select  id="version" class="form-control"  
                                                ng-model="entity.vision"  data-placeholder="选择版本">
                                            
                                                <option ng-repeat="r in visions" value="{{r.vision}}" ng-selected="{{r.vision == entity.vision}}" >V{{r.vision}}</option>
                                             </select> 
                                        </div>  
                               </div>
                               <div class="row form-group">

                                    <label class="col-md-2 control-label" for="title">
                                            标题:
                                    </label>
                                    <div class="col-md-4">
                                        <input type="text" id="updateTitle" name="title" class="form-control"  ng-model="entity.title" placeholder="标题" />
                                    </div>

                                     <label class="col-md-2 control-label" for="keys">关键字:</label>
                                     <div class="col-md-4">
                                           <input  class="form-control" id="updateKeys" name="keywords" class="form-control" ng-model="entity.keys" placeholder="关键字" />
                                     </div> 
                               </div>

                            <div class="row form-group">
                                 <label class="col-md-2 control-label" for="type">分类:</label>
                                 <div class="col-md-4"><!--updateTypeId-->
                                      <input type="text" id="updateType"  class="form-control"  ng-model="entity.typeName" placeholder="分类"
                                          ng-click="doOnLoad1('updateType');" data-toggle="modal" data-target="#typeboxbox"
                                          > 
                                           <input type="hidden" id="typeId" name="typeId" ng-model="entity.type"> 
                                 </div> 
                      
                                 <label class="col-md-2 control-label" for="range">使用范围:</label>
                                 <div class="col-md-4">
                                      <select  id="updateRange" class="form-control"  name="solutionRange"
                                         ng-model="entity.range"  data-placeholder="选择使用范围">
                                                <option ng-repeat="r in ranges" value="{{r.id}}">{{r.name}}</option>
                                        </select>   
                                </div> 
                            </div>
                                 
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="number">知识库编号:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                          <input type="text" id="updateNumber" name="solutionNumber" class="form-control"  
                                          ng-model="entity.number" placeholder="知识库编号"> 
                                    </div>             
                            </div>
                            
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="content">知识库内容:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                      <textarea ckeditor ng-model="entity.content" name="content" class="form-control"></textarea>
                                    </div>             
                            </div>
                             <div class="panel-footer text-center">
                                  <input type="button" class="btn btn-warning" value="确认更改" ng-click="updateSolutions()"> 
                                  <input type="button" class="btn btn-warning" value="取消更改" data-dismiss="modal" > 
                            </div>     
                          </form>
                          <iframe id="idiframes" name="id_iframe" ng-model="idiframes" style="display:none;"></iframe> 
                        </div> <!-- class="well well-lg" -->
                       </div><!-- class="panel" end -->
                       <!-- <div class="panel-footer text-center">
                              <a  ng-click="updateSolution();" class="btn btn-success"  value="更改">更改</a>
                       </div> -->
                </div><!--modal content-->
            </div> 
  <!--编辑知识库 end-->     

  <!--查看知识库详情 start-->     
    <div id="showSolutionDetails" class="modal fade modal-blur" tabindex="-1" role="dialog" style="display: none;">
          <div class="modal-dialog">
                <div class="modal-content  panel-danger" style="width:800px;">
                      <div class="modal-header panel-heading">
                         <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                         <h4 class="modal-title"><i class="fa fa-coffee"></i>查看知识库详情</h4>
                     </div>
                     <div class="modal-body">
                                 <div class="row form-group"> <!-- style="border:1px dashed #CCCCCC" -->
                                     <label class="col-md-2 control-label">
                                       附件
                                       <a  href="http://{{path}}/services/solution/download/{{entity.id}}">
                                          <img src="{{entity.filePic}}" >
                                       </a> 
                                     </label>
                                     <div class="col-md-4">
                                        {{entity.fileName}}
                                     </div>
                                      <label class="col-md-2 control-label" for="vision">
                                            版本:
                                       </label>
                                       <div class="col-md-4"> 
                                             <select  id="detailVersion" class="form-control"   
                                                ng-model="entity.vision"  data-placeholder="选择版本">
                                               <option ng-repeat="r in visions" value="{{r.vision}}" ng-selected="{{r.vision == entity.vision}}" >V{{r.vision}}</option>
                                             </select> 
                                        </div>  
                               </div>
                               <div class="row form-group">

                                    <label class="col-md-3 control-label" for="title">
                                            标题:
                                    </label>
                                    <div class="col-md-8">
                                       <input id="updateTitle" name="title"  disabled="true"
                                         class="form-control"  ng-model="entity.title" placeholder="标题" /> 
                                    </div>
                                </div>
                                <div class="row form-group">
                                     <label class="col-md-3 control-label" for="keys">关键字:</label>
                                     <div class="col-md-8">
                                         <input  class="form-control" id="updateKeys" name="keys" class="form-control" ng-model="entity.keys" placeholder="关键字" disabled="true" /> 
                                     </div> 
                               </div>
                            <div class="row form-group">
                                 <label class="col-md-3 control-label" for="typeName">分类:</label>
                                 <div class="col-md-8">
                                      <input  id="updateType" name="type" class="form-control"  
                                      ng-model="entity.typeName" placeholder="分类"
                                         disabled="true"
                                          ><!--  ng-click="doOnLoad('type');" data-toggle="modal" data-target="#typeboxbox -->
                                 </div> 
                              </div> 
                             <div class="row form-group">
                                 <label class="col-md-3 control-label" for="range">使用范围:</label>
                                 <div class="col-md-8">
                                      <select  id="updateRange" class="form-control"  disabled="true"
                                         ng-model="entity.range"  data-placeholder="选择使用范围">
                                                <option ng-repeat="r in ranges" value="{{r.id}}">{{r.name}}</option>
                                        </select>   
                                </div> 
                            </div>
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="number">知识库编号:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                         <input  name="number" class="form-control"  
                                          ng-model="entity.number" placeholder="知识库编号" disabled="true"> 
                                    </div>             
                            </div>
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="content">知识库内容:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                      <textarea ckeditor ng-model="entity.content" class="form-control" disabled="true"></textarea> 
                                    </div>             
                            </div>
                            <div class="panel-footer"> </div>

                        </div> 
                 </div>
       </div>
   </div> 
<!--查看知识库详情 end-->   

<!--评论知识库 start-->
    <div id="commentSolution" class="modal fade modal-blur" tabindex="-1" role="dialog" style="display: none;">
          <div class="modal-dialog">
                <div class="modal-content panel panel-success"  style="width: 800px">
                      <div class="modal-header panel-heading">
                         <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                         <h4 class="modal-title"><i class="fa  fa-heart"></i>评论知识库</h4>
                     </div>
                      <ul id="uidemo-tabs-default-demo" class="nav nav-tabs" style="margin-top: 20px">
                          <li ng-repeat="tab in commentSolution.tabs" ng-class="tab.active">
                          <a  data-toggle="tab"  ng-click="commentSolution.tabselect(tab.id);">{{tab.title}}</a>
                           </li>
                      </ul>
                      
                      <div class="tab-content tab-content-bordered">  
                      <!--知识库详情 start-->
                        <div class="tab-pane fade" ng-class="commentSolution.tabs[0].divactive">
                        <div class="panel">
                           <div class="well well-lg">
                                    <br />
                                 <div class="row form-group">
                                      <label class="col-md-2 control-label">附件
                                        <a  href="http://{{path}}/services/solution/download/{{entity.id}}">
                                          <img src="{{entity.filePic}}" >
                                       </a>
                                        </label>
                                       <div class="col-md-4">
                                         {{entity.fileName}} 
                                      </div>    
                                     
                                        <label class="col-md-2 control-label " for="version">
                                            版本:
                                       </label>
                                       <div class="col-md-4" style="float:right">
                                              <input  id="version" name="title" class="form-control"  ng-model="entity.vision" placeholder="版本" disabled />
                                             <!-- <select  id="version" class="form-control"  
                                                ng-model="entity.version"  data-placeholder="选择版本">
                                                <option></option>
                                                <option ng-repeat="r in versions" value="{{r.id}}">{{r.name}}</option>
                                             </select>  -->
                                        </div>  
                               </div>
                               <div class="row form-group">

                                    <label class="col-md-2 control-label" for="title">
                                            标题:
                                    </label>
                                    <div class="col-md-4">
                                        <input  id="title" name="title" class="form-control"  ng-model="entity.title" placeholder="标题"  disabled="true"/>
                                    </div>

                                     <label class="col-md-2 control-label" for="keys">关键字:</label>
                                     <div class="col-md-4">
                                           <input  class="form-control" id="keys" name="keys" class="form-control" ng-model="entity.keys" placeholder="关键字"  disabled="true"/>
                                     </div> 
                               </div>


                            <div class="row form-group">
                                 <label class="col-md-2 control-label" for="type">分类:</label>
                                 <div class="col-md-4">
                                      <input  id="type" name="type" class="form-control"  ng-model="entity.typeName" placeholder="分类"
                                           disabled="true"
                                          > <!-- ng-click="doOnLoad('type');" data-toggle="modal" data-target="#typeboxbox" -->
                                 </div> 
                      
                                 <label class="col-md-2 control-label" for="range">使用范围:</label>
                                 <div class="col-md-4">
                                      <select  id="range" class="form-control"   disabled="disabled"
                                         ng-model="entity.range"  data-placeholder="选择使用范围">
                                                <option ng-repeat="r in ranges" value="{{r.id}}">{{r.name}}</option>
                                        </select>   
                                </div> 
                            </div>
                                 
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="number">知识库编号:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                          <input  id="number" name="number" class="form-control"  ng-model="entity.number" placeholder="知识库编号" disabled="true"> 
                                    </div>             
                            </div>
                            
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="content">知识库内容:</label>
                                    <div class="col-md-8" style="z-indx:1px;"> 
                                      <textarea ckeditor  ng-model="entity.content" class="form-control" disabled="true"></textarea>
                                    </div>             
                            </div>
                        </div> <!-- class="well well-lg" -->
                       </div><!-- class="panel" end -->
                     </div>
                    <!--知识库详情 end-->

                      <!--查看评论 start-->
                       <div class="tab-pane fade {{commentSolution.tabs[1].divactive}}" 
                       ><!-- ng-click="findSolutionReviewByType('{{entity.id}}')" -->
                           <div class="panel"> 
                             <div class="well well-lg"> <br />
                                <div class="row form-group">
                                     <li ng-repeat="s in comments">
                                           <div class="col-md-8" style="z-indx:1px;">
                                              评论人：{{s.name}} |     发表于：{{s.time}}   |评分：{{s.score}}
                                              <hr style="height: 1px; border:none; border-top:1px dashed #CCCCCC;" /> 
                                              评论： {{s.content}} 
                                              <hr style="height: 1px; border:none; border-top:1px dashed black;" /> 
                                          </div> 
                                    </li>
                              </div>
                        </div> <!-- class="well well-lg" -->
                        </div><!-- class="panel" end -->
                      </div> <!--查看评论 end-->

                       
                       <!--评论知识库 start-->
                       <div class="tab-pane fade {{commentSolution.tabs[2].divactive}}">
                           <div class="panel"> 
                             <div class="well well-lg"> <br />
                              <div class="row form-group" ng-show="showCommentScore">
                                  <label class="col-md-2 control-label" for="score">评分:</label>
                                  <div class="col-md-8" style="z-indx:1px;line-height:30px;;">
                                  <!-- TODO rating plugin -->
                           <!--              <input id="input-2ba" type="number" class="rating" min="0" max="5" step="0.5" data-size="sm"
                                         data-symbol="&#xe005;" data-default-caption="{rating} hearts" data-star-captions="{}"> -->
                                     <!--  <input id="input-id" type="number" class="rating" min=0 max=5 step=0.5 data-size="lg" > -->
                                  </div>
                              </div>
                              <div class="row form-group">
                                    <label class="col-md-2 control-label" for="content">评论:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                      <textarea ckeditor id="reviewcontent"  ng-model="reviewcontent" class="form-control"></textarea>
                                    </div> 
                              </div>
                              
                              <div class="panel-footer text-center">
                                     <a  ng-click="saveComment();" class="btn btn-success" id="sub1" value="发表">发表</a>
                              </div>
                         </div> <!-- class="well well-lg" -->
                       </div><!-- class="panel" end -->
                     </div> <!--评论知识库 end-->

                   
                  </div><!--tab-content-->
                </div><!--modal content-->
              </div>
        </div> 
        <!--评论知识库 end-->     

       <!--typeboxbox start-->
       <div id="typeboxbox" class="modal fade modal-blur" tabindex="-1" role="dialog" style="display:none;">
          <div class="modal-dialog modal-lg">
             <div class="modal-content panel-info" style="width:400px;" >
                  <div class="modal-header panel-heading">
                       <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                       <h4 class="modal-title">分类</h4>
                  </div>
                  <div class="modal-body">
                       <div id="treeboxbox_tree1" style="width:350px;height:400px;background-color:#f5f5f5;"></div>  
                       <div class="clearfix igoalpopupbtn">
                         <button   class="btn me-margin-top8 pull-right me-margin-right10" type="button"  data-dismiss="modal" ng-click="chooseTreeBox();"
                         >确定</button> 
                       </div> 
                 </div>
              </div>
          </div>
       </div> 
      <!--typeboxbox end-->   
</div>
